<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
		<base href="<%=basePath%>">
		<title>上传包含学号的Excel文件</title>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/js/jquery-latest.pack.js'></script>
		<script type="text/javascript"
			src="<%=request.getContextPath()%>/js/jqueryCopyEvent.js"></script>
		<script type="text/javascript"
			src="<%=request.getContextPath()%>/js/jquery.corner.js"></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/js/noConflictOfJquery.js'></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/interface/dWRCollegeMajorAction.js'></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/interface/uploadAction.js'></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/engine.js'></script>
		<script type='text/javascript'
			src='<%=request.getContextPath()%>/dwr/util.js'></script>
		<script type="text/javascript"
			src="<%=request.getContextPath()%>/js/progressBar.js"></script>
		
		<link rel="stylesheet"
			href="<%=request.getContextPath()%>/css/common.css" type="text/css" />
		<script>
			function checkOnSubmit(){
				var file=document.getElementById("uploadFile");
				if(''==file.value){
					alert("请选择上传文件！！");
					return false;
				}else{
					var progressBar=document.getElementById("div_ProgressBar");
					progressBar.style.visibility="visible";
					return true;
				}
			}
		</script>

	</head>

	<body>
		<div id="page_container">
			<jsp:include page="studentnav.jsp"></jsp:include>
			<h2>
				上传学生信息
			</h2>
			 <iframe id='target_upload' name='target_upload' src=''
			style='display: none'></iframe>
			<s:form action="upload/uploadFormatedStudentInfo.action" id="uploadForm"
				method="post" enctype="multipart/form-data" theme="simple" target="target_upload">
				<table class="table_common">
					<tr>
						<td class="td_left">
							请选择Excel文件：
						</td>
						<td class="td_right">
							<s:file id="uploadFile" name="uploadedFile"></s:file>
						</td>
					</tr>
				</table>
				<input type="button" id="subButton" value="上传">
				<input type="button" id="cancelButton" value="取消">
			</s:form>
			

		 <div id="progress">
   			<div id="title"><span id="text">上传进度</span>
   			</div>
   			<div id="info"></div>
   		</div>

		</div>
	</body>
</html>
